package com.santu.edu.supporter.biz.order.helpbuy.service;

import com.santu.edu.supporter.biz.order.common.pojo.enums.OrderPayStatusEnum;
import com.santu.edu.supporter.biz.order.common.pojo.enums.OrderStatusEnum;
import com.santu.edu.supporter.biz.order.helpbuy.pojo.dto.HelpBuyOrderDTO;
import com.santu.edu.supporter.biz.order.helpbuy.pojo.params.HbOrderAddParam;
import com.santu.edu.supporter.biz.order.helpbuy.pojo.params.HbOrderUpdateParam;
import com.santu.edu.supporter.util.PageData;

/**
 * @author luoyaoqi
 * @createTime 2024/2/21
 * @description
 */
public interface HelpBuyService {
    /**
     * 添加订单
     *
     * @param addParam
     * @return
     */
    Boolean addOrder(HbOrderAddParam addParam);

    /**
     * 更新订单
     *
     * @param updateParam
     * @return
     */
    Boolean updateOrder(HbOrderUpdateParam updateParam);

    /**
     * 取消订单
     *
     * @param orderId
     * @return
     */
    Boolean cancelOrder(String orderId);

    /**
     * 获取订单列表
     *
     * @param schoolId
     * @param userId
     * @param orderType
     * @param page
     * @param size
     * @return
     */
    PageData<HelpBuyOrderDTO> getOrderList(String schoolId, String userId, Integer orderType, int page, int size);

    /**
     * 更新订单支付状态
     *
     * @param orderId
     * @param orderStatus
     * @param nowOrderStatus
     */
    void updateOrderStatus(String orderId, OrderStatusEnum orderStatus,OrderStatusEnum nowOrderStatus);
}
